# -*- codeing = utf-8 -*-
# @Time : 2022/9/12 16:30
# @Author : 计科1814-16-徐澳
# @Software: PyCharm
sum = 0
for i in range(1,101):
    sum+=i
print("使用for循环计算1-100的和为:",sum)

sum = 0
i=1
while i<=100:
    sum+=i
    i+=1
print("使用while循环计算1-100的和为:",sum)